-
Notifications
You must be signed in to change notification settings - Fork 20
feat: Add support for interpolator #335
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds support for running the interpolator on GRIB files from forecaster models, enabling interpolation on file-based inputs rather than just analysis data.
Key changes:
- Added support for interpolation from GRIB files with different reference date handling
- Enhanced pre-processors to work with State objects instead of just FieldList objects
Reviewed Changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 5 comments.
Show a summary per file
File | Description |
---|---|
src/anemoi/inference/runners/interpolator.py | Added file-based interpolation support and device management |
src/anemoi/inference/runners/default.py | Added distributed process group cleanup and reference date handling |
src/anemoi/inference/runner.py | Enhanced with distributed computing, improved tensor operations, and better device handling |
src/anemoi/inference/pre_processors/no_missing_values.py | Updated to process State objects instead of FieldList |
src/anemoi/inference/pre_processors/forward_transform_filter.py | Updated to process State objects instead of FieldList |
src/anemoi/inference/pre_processors/extract.py | New processor for extracting subsets of data using masks or slices |
src/anemoi/inference/inputs/gribfile.py | Added support for reference date index parameter |
src/anemoi/inference/inputs/ekd.py | Enhanced state creation with reference date support and improved pre-processing |
src/anemoi/inference/inputs/cutout.py | Added kwargs support for input state creation |
src/anemoi/inference/device.py | Enhanced device selection with distributed computing support |
src/anemoi/inference/config/init.py | Relaxed configuration validation to allow extra fields |
pyproject.toml | Updated omegaconf version constraint |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Thanks for this! As you say, I think we first need to discuss how to bring this functionality into the codebase. I think this would be a good topic for in two weeks when Harrison and I are in Zurich ? |
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
for more information, see https://pre-commit.ci
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Harrison Cook <[email protected]>
Co-authored-by: Harrison Cook <[email protected]>
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice, thanks for the hard work on this!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks for addressing all the concerns we raised.
Description
This PR adds support for running the interpolator on:
Related to #345
Close #310
What issue or task does this change relate to?
N/A
Additional notes
This draft includes all the changes introduced by @OpheliaMiralles in anemoi-inference in order to run interpolation. We should have a discussion on what changes should be factored out in a separate PR.
As a contributor to the Anemoi framework, please ensure that your changes include unit tests, updates to any affected dependencies and documentation, and have been tested in a parallel setting (i.e., with multiple GPUs). As a reviewer, you are also responsible for verifying these aspects and requesting changes if they are not adequately addressed. For guidelines about those please refer to https://anemoi.readthedocs.io/en/latest/
By opening this pull request, I affirm that all authors agree to the Contributor License Agreement.